﻿using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.Text;
using System.Windows.Input;
using Autorent.Desktop.Main;
using Autorent.Desktop.Model.AutorentMngrServiceReference;
using Autorent.Desktop.Model.Services;
using Autorent.Desktop.Modules.Autoes.Services;
using Autorent.Desktop.Modules.Autoes.Views;

namespace Autorent.Desktop.Modules.Autoes.ViewModels
{
    public class SearchAutoViewModel
    {
        private readonly IAutoesRepository _autoRepository;
        private readonly IAutoClassesRepository _autoClassRepository;

        public SearchAutoViewModel(SearchAutoView view, IAutoClassesRepository classRepository, IAutoesRepository autoRepository)
        {
            this._autoRepository = autoRepository;
            this._autoClassRepository = classRepository;
            this.View = view;
            this.View.Model = this;
        }

        public SearchAutoView View { get; set; }

        public ObservableCollection<AutoClass> ClassAuto
        {
            get { return _autoClassRepository.GetAutoClasses(); }
        }


        public ICommand SearchAuto
        {
            get { return new RelayCommand(args => searchAuto()); }
        }


        private void searchAuto()
        { 
        
        }
    }
}
